import java.io.*;
import java.util.*;

public class test {
    public static PrintWriter pr = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    public static Read in = new Read();
    public static long n;
    public static long m;
    public static long k;
    // 蓝桥杯 肖恩的乘法表(★★)
    public static void main(String[] args) throws IOException {
        n = in.nextLong();
        m = in.nextLong();
        k = in.nextLong();
        //如果 n = 3 m = 5
        //则有表:
        // 1  2  3  4  5
        // 2  4  6  8  10
        // 3  6  9  12  15
        // (可以一列一列查,每一列可采用二分)
        // 找第 k 大,需要比它大的有 k - 1 个
        long l = 1;
        long r = n * m + 5;
        // 1 1 1 1 0 0 0
        //         k
        while(l < r){
            long mid = l + (r - l) / 2;
            if(checkRow(mid) == 0){
                r = mid;
            }else {
                l = mid + 1;
            }
        }
        System.out.println(l);
    }
    // 遍历第一行
    // (<K)    (>=k)
    // 1 1 1 1 0 0 0
    public static int checkRow(long mid0){
        long sum = 0;
        for(int i = 1;i <= m;i++){
            sum += Math.min(mid0 / i, n);
            if(sum >= k) return 0;
        }
        return 1;
    }
    // 蓝桥杯 大衣的旅行(⭐⭐⭐)
    public static void main1(String[] args) throws IOException{
        int T = in.nextInt();
        while(T-- > 0){
            int n = in.nextInt();
            int m = in.nextInt();
            int k = in.nextInt();
            int[][] arr = new int[n + 1][m + 1];
            //二维前缀和.用于快速判断指定范围内空间是否足够
            long[][] sum = new long[n + 1][m + 1];
            for(int i = 1;i <= n;i++){
                for(int j = 1;j <= m;j++){
                    arr[i][j] = in.nextInt();
                    sum[i][j] = arr[i][j] +
                            sum[i - 1][j] + sum[i][j - 1] - sum[i - 1][j - 1];
                    //System.out.print(sum[i][j] + " ");
                }
            }
            if(sum[n][m] <= k) {
                System.out.println(-1);
                continue;
            }
            //最近距离为1
            //最远距离为斜对角
            int l = 0;int r = Math.max(n,m);
            //01单调.查找0的左位置
            //1 1 1 1 0 0 0 0
            while(l < r){
                int mid = l + (r - l) / 2;
                int flg = 0;//默认为住不下
                for(int i = 1;i <= n;i++){
                    for(int j = 1;j <= m;j++){
                        //为矩形才能使距离最远学生最近
                        int x1 = Math.max(i - mid,1);
                        int y1 = Math.max(j - mid,1);
                        int x2 = Math.min(i + mid,n);
                        int y2 = Math.min(j + mid,m);
                        //System.out.println("x1:" + x1 + " y1:" + y1 + " x2:" + x2 + " y2:" + y2);
                        //查找规定范围内住宿空间
                        long s = sum[x2][y2] - sum[x1-1][y2]
                                - sum[x2][y1-1] + sum[x1-1][y1-1];
                        if(s > k && arr[i][j] != 0) flg = 1;
                    }
                }
                if(flg == 0){
                    l = mid + 1;
                }else {
                    r = mid;
                }
            }
            System.out.println(l);
        }
    }
    //蓝桥杯 求解组合数(⭐)
    public static void main2(String[] args) throws IOException{
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int m = in.nextInt();
        int c = in.nextInt();
        long[][] arr = new long[n + 5][m + 5];
        arr[0][1] = 1;
        for(int i = 1;i <= n;i++){
            for(int j = 1;j <= m + 1;j++){
                arr[i][j] = (arr[i-1][j-1] + arr[i-1][j]) % c;
                //System.out.print(arr[i][j] + " ");
            }
            //System.out.println();
        }
        System.out.println(arr[n][m + 1]);
    }
}
class Read{
    StringTokenizer st = new StringTokenizer("");
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String next() throws IOException{
        while(!st.hasMoreTokens()){
            st = new StringTokenizer(br.readLine());
        }
        return st.nextToken();
    }
    int nextInt() throws IOException{
        return Integer.parseInt(next());
    }
    long nextLong() throws IOException{
        return Long.parseLong(next());
    }
    double nextDouble() throws IOException{
        return Double.parseDouble(next());
    }
}
